-
Notifications
You must be signed in to change notification settings - Fork 4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(core): pass environment variables to CustomResourceProvider #10560
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't understand why one would need this. Wouldn't you pass all configuration into the CustomResource itself, not the provider?
These configuration are needed for the lambda itself. I agree that same thing can potentially be achieved by passing the details to the |
return undefined; | ||
} | ||
|
||
const variables: { [key: string]: string } = {}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wait, why is this not simply
return { Variables: env };
?
We're copying from a K/V map into a K/V map. Is there value in the copying?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is done to ensure the hash of lambda asset does not change per deployment based on order of the keys (notice we are sorting the keys in line 198)
I got the reference for this from the Lambda Function implementation
Thank you for contributing! Your pull request will be updated from master and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork). |
AWS CodeBuild CI Report
Powered by github-codebuild-logs, available on the AWS Serverless Application Repository |
Thank you for contributing! Your pull request will be updated from master and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork). |
Add environment prop to CustomResourceProvider
closes #9668
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license